-
Notifications
You must be signed in to change notification settings - Fork 4.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: Enhance test stability #4566
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…nd map functions to prevent errors 🐛 (actionsMainPage-shard-1.spec.ts): remove redundant zoom_out click 🐛 (auto-login-off.spec.ts): reduce wait time from 2000ms to 1000ms 🐛 (freeze-path.spec.ts): change click target from "openai" to "OpenAI" for consistency 🐛 (freeze.spec.ts): change click target from "Split Text" to "Split Text" for consistency 🐛 (Dynamic Agent.spec.ts): skip test execution 🐛 (Hierarchical Agent.spec.ts): skip test execution 🐛 (Sequential Task Agent.spec.ts): skip test execution 🐛 (Simple Agent.spec.ts): skip test execution 🐛 (decisionFlow.spec.ts): change search input from "conditional router" to "if else" 🐛 (similarity.spec.ts): change search input from "openai" to "openai embedding" 🐛 (fileUploadComponent.spec.ts): enable test for file upload functionality 📝 (deleteComponents.spec.ts): Remove commented out code and enable test for deleting a component 📝 (deleteFlows.spec.ts): Enable test for deleting a flow 📝 (starter-projects.spec.ts): Enable test for interacting with starter projects 📝 (store-shard-3.spec.ts): Enable tests for ordering visualization and filtering by type 📝 (generalBugs-shard-13.spec.ts): Enable test for sharing a component on the store
Cristhianzl
requested review from
mfortman11,
ogabrielluiz,
NadirJ,
lucaseduoli and
anovazzi1
November 13, 2024 13:25
dosubot
bot
added
the
size:L
This PR changes 100-499 lines, ignoring generated files.
label
Nov 13, 2024
… multiple shards for better parallelization 🔧 (typescript_test.yml): enable playwright test execution with shard index and total for parallel test execution
mfortman11
approved these changes
Nov 13, 2024
ogabrielluiz
force-pushed
the
cz/fix-tests-FE
branch
from
November 13, 2024 13:37
a3e07af
to
b7cf9e8
Compare
…nd map functions to prevent errors 🐛 (actionsMainPage-shard-1.spec.ts): remove redundant zoom_out click 🐛 (auto-login-off.spec.ts): reduce wait time from 2000ms to 1000ms 🐛 (freeze-path.spec.ts): change click target from "openai" to "OpenAI" for consistency 🐛 (freeze.spec.ts): change click target from "Split Text" to "Split Text" for consistency 🐛 (Dynamic Agent.spec.ts): skip test execution 🐛 (Hierarchical Agent.spec.ts): skip test execution 🐛 (Sequential Task Agent.spec.ts): skip test execution 🐛 (Simple Agent.spec.ts): skip test execution 🐛 (decisionFlow.spec.ts): change search input from "conditional router" to "if else" 🐛 (similarity.spec.ts): change search input from "openai" to "openai embedding" 🐛 (fileUploadComponent.spec.ts): enable test for file upload functionality 📝 (deleteComponents.spec.ts): Remove commented out code and enable test for deleting a component 📝 (deleteFlows.spec.ts): Enable test for deleting a flow 📝 (starter-projects.spec.ts): Enable test for interacting with starter projects 📝 (store-shard-3.spec.ts): Enable tests for ordering visualization and filtering by type 📝 (generalBugs-shard-13.spec.ts): Enable test for sharing a component on the store
… multiple shards for better parallelization 🔧 (typescript_test.yml): enable playwright test execution with shard index and total for parallel test execution
ogabrielluiz
force-pushed
the
cz/fix-tests-FE
branch
from
November 13, 2024 13:59
b7cf9e8
to
40f38be
Compare
…r OpenAI models and Search API 🐛 (Travel Planning Agent.spec.ts): Fix issue with clicking the wrong button for running chat output 🐛 (Travel Planning Agent.spec.ts): Fix issue with checking rate limit and skipping test logic 🐛 (Travel Planning Agent.spec.ts): Fix issue with checking output text for lowercase city names 🐛 (Vector Store.spec.ts): Fix issue with clicking the wrong button for creating a new flow 🐛 (Vector Store.spec.ts): Fix issue with filling the wrong input field for collection name in Vector Store RAG test
…nctionality not working with uplift designs
…out code 📝 (dropdownComponent.spec.ts): Update dropdown selection to match new text 📝 (starter-projects.spec.ts): Remove unused template IDs 📝 (store-shard-1.spec.ts): Update test.skip to test.skip for consistency 📝 (generalBugs-shard-10.spec.ts): Refactor test cases for promptText and newPromptText 📝 (generalBugs-shard-6.spec.ts): Add delay before interacting with elements to ensure stability
📝 (frontend): Refactor dropdownComponent tests for better readability and maintainability 📝 (frontend): Add new starter project templates for extended features testing
…itionals for userAgentInfo.os.name.includes("Mac") in multiple test files to simplify and improve code readability. Update keyboard shortcuts to use 'ControlOrMeta' for cross-platform compatibility. ✨ (stop-button-playground.spec.ts): update keyboard shortcut to select all text to be compatible with both Control and Meta keys for better cross-platform support ✨ (generalBugs-shard-7.spec.ts): update keyboard shortcut to select all text to be compatible with both Control and Meta keys for better cross-platform support
… improve test reliability and prevent false negatives
…t successfully" message to allow for longer build times ✨ (Simple Agent.spec.ts): add additional test cases to check for the presence of "apple" in chat messages and ensure the total length of chat messages is greater than 100 characters
…t to improve test efficiency
…lements to ensure proper rendering and improve test reliability
ogabrielluiz
added
lgtm
This PR has been approved by a maintainer
and removed
lgtm
This PR has been approved by a maintainer
labels
Nov 13, 2024
…and dragging elements in the playground test 📝 (deleteComponents.spec.ts): update selectors for clicking buttons and elements in the deleteComponents test 📝 (deleteFlows.spec.ts): update selectors for clicking buttons and elements in the deleteFlows test 📝 (starter-projects.spec.ts): update selectors for starter projects in the extended features test to match changes in the application's UI.
…lity 🔧 (playground.spec.ts): skip test "fresh start playground" to exclude it from test runs ♻️ (playground.spec.ts): refactor test "fresh start playground" to improve readability and maintainability ♻️ (dropdownComponent.spec.ts): refactor test "dropDownComponent" for better clarity and consistency
…o run during testing.
… compatibility in tests
…olOrMeta" instead of "control" for cross-platform compatibility
…put in the playground 🔧 (Vector Store.spec.ts): Fix incorrect click on button_run_astra db by selecting the last element 🔧 (Vector Store.spec.ts): Fix incorrect click on button_run_astra db by selecting the first element 🔧 (Vector Store.spec.ts): Update click action on input-chat-playground to simulate pressing Enter key 🔧 (similarity.spec.ts): Update wait time from 2000ms to 500ms for page load 🔧 (similarity.spec.ts): Reduce wait time from 1000ms to 500ms for various interactions 🔧 (similarity.spec.ts): Remove commented-out code for text input and output interactions 🔧 (textInputOutput.spec.ts): Remove skipped test and clean up unnecessary commented-out code
… selecting all text and copying in the test case to ensure proper functionality
…th ctrl + A on advanced modal by removing unnecessary code block
dosubot
bot
added
size:XL
This PR changes 500-999 lines, ignoring generated files.
and removed
size:L
This PR changes 100-499 lines, ignoring generated files.
labels
Nov 13, 2024
…opdown options and values for dropdownComponent
…condition for userAgentInfo 🔧 (similarity.spec.ts): Remove unnecessary comment and empty line
diogocabral
pushed a commit
to headlinevc/langflow
that referenced
this pull request
Nov 26, 2024
* 🐛 (genericIconComponent/index.tsx): fix optional chaining for split and map functions to prevent errors 🐛 (actionsMainPage-shard-1.spec.ts): remove redundant zoom_out click 🐛 (auto-login-off.spec.ts): reduce wait time from 2000ms to 1000ms 🐛 (freeze-path.spec.ts): change click target from "openai" to "OpenAI" for consistency 🐛 (freeze.spec.ts): change click target from "Split Text" to "Split Text" for consistency 🐛 (Dynamic Agent.spec.ts): skip test execution 🐛 (Hierarchical Agent.spec.ts): skip test execution 🐛 (Sequential Task Agent.spec.ts): skip test execution 🐛 (Simple Agent.spec.ts): skip test execution 🐛 (decisionFlow.spec.ts): change search input from "conditional router" to "if else" 🐛 (similarity.spec.ts): change search input from "openai" to "openai embedding" 🐛 (fileUploadComponent.spec.ts): enable test for file upload functionality 📝 (deleteComponents.spec.ts): Remove commented out code and enable test for deleting a component 📝 (deleteFlows.spec.ts): Enable test for deleting a flow 📝 (starter-projects.spec.ts): Enable test for interacting with starter projects 📝 (store-shard-3.spec.ts): Enable tests for ordering visualization and filtering by type 📝 (generalBugs-shard-13.spec.ts): Enable test for sharing a component on the store * ⬆️ (typescript_test.yml): update matrix configuration to run tests on multiple shards for better parallelization 🔧 (typescript_test.yml): enable playwright test execution with shard index and total for parallel test execution * 🐛 (genericIconComponent/index.tsx): fix optional chaining for split and map functions to prevent errors 🐛 (actionsMainPage-shard-1.spec.ts): remove redundant zoom_out click 🐛 (auto-login-off.spec.ts): reduce wait time from 2000ms to 1000ms 🐛 (freeze-path.spec.ts): change click target from "openai" to "OpenAI" for consistency 🐛 (freeze.spec.ts): change click target from "Split Text" to "Split Text" for consistency 🐛 (Dynamic Agent.spec.ts): skip test execution 🐛 (Hierarchical Agent.spec.ts): skip test execution 🐛 (Sequential Task Agent.spec.ts): skip test execution 🐛 (Simple Agent.spec.ts): skip test execution 🐛 (decisionFlow.spec.ts): change search input from "conditional router" to "if else" 🐛 (similarity.spec.ts): change search input from "openai" to "openai embedding" 🐛 (fileUploadComponent.spec.ts): enable test for file upload functionality 📝 (deleteComponents.spec.ts): Remove commented out code and enable test for deleting a component 📝 (deleteFlows.spec.ts): Enable test for deleting a flow 📝 (starter-projects.spec.ts): Enable test for interacting with starter projects 📝 (store-shard-3.spec.ts): Enable tests for ordering visualization and filtering by type 📝 (generalBugs-shard-13.spec.ts): Enable test for sharing a component on the store * ⬆️ (typescript_test.yml): update matrix configuration to run tests on multiple shards for better parallelization 🔧 (typescript_test.yml): enable playwright test execution with shard index and total for parallel test execution * 🐛 (Travel Planning Agent.spec.ts): Fix issue with setting API keys for OpenAI models and Search API 🐛 (Travel Planning Agent.spec.ts): Fix issue with clicking the wrong button for running chat output 🐛 (Travel Planning Agent.spec.ts): Fix issue with checking rate limit and skipping test logic 🐛 (Travel Planning Agent.spec.ts): Fix issue with checking output text for lowercase city names 🐛 (Vector Store.spec.ts): Fix issue with clicking the wrong button for creating a new flow 🐛 (Vector Store.spec.ts): Fix issue with filling the wrong input field for collection name in Vector Store RAG test * 🔧 (generalBugs-shard-4.spec.ts): skip test case temporarily due to functionality not working with uplift designs * Update test to use 'message history' instead of 'chat memory' in sidebar search input * Update test selectors and expected values in dropdownComponent.spec.ts * 📝 (Simple Agent.spec.ts): Remove unnecessary test.skip and commented out code 📝 (dropdownComponent.spec.ts): Update dropdown selection to match new text 📝 (starter-projects.spec.ts): Remove unused template IDs 📝 (store-shard-1.spec.ts): Update test.skip to test.skip for consistency 📝 (generalBugs-shard-10.spec.ts): Refactor test cases for promptText and newPromptText 📝 (generalBugs-shard-6.spec.ts): Add delay before interacting with elements to ensure stability * Refactor tests to use `ControlOrMeta` for cross-platform keyboard shortcuts * ✅ (Simple Agent.spec.ts): update timeout value for waitForSelector to improve test reliability and prevent false negatives * Handle undefined stars in GithubStarComponent to prevent errors * Add waitForSelector to ensure sidebar search input is visible before interaction in chatInputOutput test * ✅ (Simple Agent.spec.ts): update timeout value to 5 minutes for "built successfully" message to allow for longer build times ✨ (Simple Agent.spec.ts): add additional test cases to check for the presence of "apple" in chat messages and ensure the total length of chat messages is greater than 100 characters * 🐛 (Simple Agent.spec.ts): reduce timeout for "built successfully" text to improve test efficiency * ✅ (auto-login-off.spec.ts): add delay before checking visibility of elements to ensure proper rendering and improve test reliability * Fix indentation in TypeScript test workflow file * Update test IDs and expected values in dropdownComponent.spec.ts * 📝 (playground.spec.ts): remove redundant code related to zooming out and dragging elements in the playground test 📝 (deleteComponents.spec.ts): update selectors for clicking buttons and elements in the deleteComponents test 📝 (deleteFlows.spec.ts): update selectors for clicking buttons and elements in the deleteFlows test 📝 (starter-projects.spec.ts): update selectors for starter projects in the extended features test to match changes in the application's UI. * ✅ (playground.spec.ts): remove skip from the test case to enable it to run during testing. * Refactor timeout in playground test for better stability --------- Co-authored-by: Gabriel Luiz Freitas Almeida <[email protected]> Co-authored-by: anovazzi1 <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes several changes focused on improving the tests and codebase in the
src/frontend
directory. The key changes involve modifying test behaviors, updating timeouts, and skipping certain tests conditionally based on environment variables.Test Improvements:
src/frontend/tests/core/features/actionsMainPage-shard-1.spec.ts
: Added a wait timeout to ensure modal visibility before clicking.src/frontend/tests/core/features/auto-login-off.spec.ts
: Adjusted wait timeouts to improve test stability and added additional wait timeouts for better synchronization. [1] [2] [3] [4]src/frontend/tests/core/features/freeze-path.spec.ts
: Updated text match criteria to be case-sensitive and exact.src/frontend/tests/core/features/freeze.spec.ts
: Ensured the correct element is clicked by specifying the last occurrence.Conditional Test Skipping:
src/frontend/tests/core/integrations/Dynamic Agent.spec.ts
,src/frontend/tests/core/integrations/Hierarchical Agent.spec.ts
,src/frontend/tests/core/integrations/Sequential Task Agent.spec.ts
,src/frontend/tests/core/integrations/Simple Agent.spec.ts
: Skipped tests conditionally based on the presence of theOPENAI_API_KEY
environment variable. [1] [2] [3] [4]src/frontend/tests/extended/features/deleteComponents.spec.ts
: Re-enabled and refactored the test to conditionally skip based on theSTORE_API_KEY
environment variable.Other Changes:
src/frontend/tests/core/integrations/decisionFlow.spec.ts
: Updated the search input to use a more accurate term.src/frontend/tests/core/integrations/similarity.spec.ts
: Refined the search input term for better specificity. [1] [2]src/frontend/tests/core/unit/fileUploadComponent.spec.ts
: Re-enabled the file upload test.src/frontend/tests/extended/features/deleteFlows.spec.ts
,src/frontend/tests/extended/features/starter-projects.spec.ts
,src/frontend/tests/extended/features/store-shard-3.spec.ts
,src/frontend/tests/extended/regression/generalBugs-shard-13.spec.ts
: Re-enabled various tests that were previously skipped. [1] [2] [3] [4] [5]Codebase Simplification:
src/frontend/src/components/genericIconComponent/index.tsx
: Simplified code by using optional chaining for better readability.